package com.hqd.ch03.v41.web.servlet;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Locale;

/**
 * web环境国际化接口
 */
public interface LocaleResolver {
    /**
     * 查找国际化
     *
     * @param request
     * @return
     */
    Locale resolveLocale(HttpServletRequest request);

    /**
     * 设置国际化
     *
     * @param request
     * @param response
     * @param locale
     */
    void setLocale(HttpServletRequest request, HttpServletResponse response, Locale locale);
}
